package com.ruoyi.view.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.view.mapper.WeatherStatisticsMapper;
import com.ruoyi.view.domain.WeatherStatistics;
import com.ruoyi.view.service.IWeatherStatisticsService;
import com.ruoyi.common.core.text.Convert;

/**
 * weather_statisticsService业务层处理
 * 
 * @author ruoyi
 * @date 2023-04-11
 */
@Service
public class WeatherStatisticsServiceImpl implements IWeatherStatisticsService 
{
    @Autowired
    private WeatherStatisticsMapper weatherStatisticsMapper;

    /**
     * 查询weather_statistics
     * 
     * @param weather weather_statistics主键
     * @return weather_statistics
     */
    @Override
    public WeatherStatistics selectWeatherStatisticsByWeather(String weather)
    {
        return weatherStatisticsMapper.selectWeatherStatisticsByWeather(weather);
    }

    /**
     * 查询weather_statistics列表
     * 
     * @param weatherStatistics weather_statistics
     * @return weather_statistics
     */
    @Override
    public List<WeatherStatistics> selectWeatherStatisticsList(WeatherStatistics weatherStatistics)
    {
        return weatherStatisticsMapper.selectWeatherStatisticsList(weatherStatistics);
    }

    /**
     * 新增weather_statistics
     * 
     * @param weatherStatistics weather_statistics
     * @return 结果
     */
    @Override
    public int insertWeatherStatistics(WeatherStatistics weatherStatistics)
    {
        return weatherStatisticsMapper.insertWeatherStatistics(weatherStatistics);
    }

    /**
     * 修改weather_statistics
     * 
     * @param weatherStatistics weather_statistics
     * @return 结果
     */
    @Override
    public int updateWeatherStatistics(WeatherStatistics weatherStatistics)
    {
        return weatherStatisticsMapper.updateWeatherStatistics(weatherStatistics);
    }

    /**
     * 批量删除weather_statistics
     * 
     * @param weathers 需要删除的weather_statistics主键
     * @return 结果
     */
    @Override
    public int deleteWeatherStatisticsByWeathers(String weathers)
    {
        return weatherStatisticsMapper.deleteWeatherStatisticsByWeathers(Convert.toStrArray(weathers));
    }

    /**
     * 删除weather_statistics信息
     * 
     * @param weather weather_statistics主键
     * @return 结果
     */
    @Override
    public int deleteWeatherStatisticsByWeather(String weather)
    {
        return weatherStatisticsMapper.deleteWeatherStatisticsByWeather(weather);
    }
}
